Conversation
|
What we're going to want in the short-term is one "unreviewed" queue which is only Japanese (this PR makes this possible), and another "unreviewed" which is everything except Japanese. To support this, maybe we need backend support for "not" tag filtering? As a small UI tweak, I think we'll probably want the most common options at the top of the language drop-down menu: "everything", "english", "japanese", "portuguese", "german", "everything minus japanese" |
|
@bnewbold makes sense! I built the dropdown to be a bit more robust so that we can choose multiple language and exclude multiple languages from the queue. Of course, this also covers the use-case you drew out. |
|
Your Render PR Server URL is https://ozone-staging-pr-25.onrender.com. Follow its progress at https://dashboard.render.com/web/srv-cn9noeg21fec73e7cs5g. |
|
Your Render PR Server URL is https://ozone-sandbox-pr-25.onrender.com. Follow its progress at https://dashboard.render.com/web/srv-cn9nof821fec73e7csd0. |
| const excludedTags = excludeTagsParam?.split(',') || [] | ||
| const includedLanguages = tags | ||
| .filter((tag) => tag.includes('lang:')) | ||
| .map((tag) => tag.split(':')[1]) |
There was a problem hiding this comment.
This little snippet tag.split(':')[1] could be nicely self-documented by pulling it out into a function with a nice name.
| .filter((tag) => tag.includes('lang:')) | ||
| .map((tag) => tag.split(':')[1]) | ||
| const excludedLanguages = excludedTags | ||
| .filter((tag) => tag.includes('lang:')) |
There was a problem hiding this comment.
Probably fine either way, but figure this is just as easy!
| .filter((tag) => tag.includes('lang:')) | |
| .filter((tag) => tag.startsWith('lang:')) |
| onClick={() => !isDisabled && onSelect(code2)} | ||
| key={code2} | ||
| > | ||
| {LANGUAGES_MAP_CODE2[code2].name} |
There was a problem hiding this comment.
Is there anything that guarantees that LANGUAGES_MAP_CODE2[code2] will exist? Maybe we could just document near availableLanguageCodes that it must be a subset of LANGUAGES_MAP_CODE2. Alternately we could mark certain items in LANGUAGES_MAP_CODE2 as "available".
There was a problem hiding this comment.
yeah documenting availableLanguageCodes should do the job because the languages I've added are the ones that bryan suggested and overtime we may add more but even then, the LANGUAGES_MAP_CODE2 is quite comprehensive so I don't see a lang code ever missing there.
bnewbold
left a comment
There was a problem hiding this comment.
overall, this looks great!
I tested a bit in prod and excluding Japanese didn't seem to work. When toggling through "quick take action" (aka, left/right arrow keys), I came across japanese posts, and could see that they had been tagged lang:ja, and I could confirm that language filter setting was just "not japanese" (no positive selection).
…tion Report Action
Depends on bluesky-social/atproto#2161
language_filter.mov
Updated look at the language picker 👇🏽

Notice that it allows moderators to select one or more languages and/or exclude one or more languages from the queue.